package com.zhongyewx.teachercert.db.entity;

import android.arch.persistence.room.ColumnInfo;
import android.arch.persistence.room.Entity;
import android.arch.persistence.room.Index;
import android.arch.persistence.room.PrimaryKey;
import android.support.annotation.NonNull;

import java.io.Serializable;

@Entity(tableName = "zyteachercert_user_table", indices = {@Index("user_name")})
public class UserEntity  implements Serializable {
    //设置主键，自增(autoGenerate = true)
    @PrimaryKey
    @NonNull
    @ColumnInfo(name = "user_group_id")//字段映射具体的数据表字段名
    private String userGroupId;

    @ColumnInfo(name = "user_name")
    private String userName;

    @NonNull
    public String getUserGroupId() {
        return userGroupId;
    }

    public void setUserGroupId(@NonNull String userGroupId) {
        this.userGroupId = userGroupId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }
}
